package com.zky.group.grouphead.feign;

import com.zky.common.entity.OrderEntity;
import com.zky.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Map;

@FeignClient("group-order")
@RequestMapping("grouporder/order")
public interface OrderFeignService {


    /**
     * 列表
     */
    @RequestMapping("/list")
//    @RequiresPermissions("grouporder:order:list")
    public R list(@RequestParam Map<String, Object> params);


    /**
     * 信息
     */
    @RequestMapping("/info/{orderId}")
//    @RequiresPermissions("grouporder:order:info")
    public R info(@PathVariable("orderId") Long orderId);

    /**
     * 保存
     */
    @RequestMapping("/save")
//    @RequiresPermissions("grouporder:order:save")+
    public R save(@RequestBody OrderEntity order);

    /**
     * 修改
     */
    @RequestMapping("/update")
//    @RequiresPermissions("grouporder:order:update")
    public R update(@RequestBody OrderEntity order);

    /**
     * 删除
     */
    @RequestMapping("/delete")
//    @RequiresPermissions("grouporder:order:delete")
    public R delete(@RequestBody Long[] orderIds);


}
